package cn.tedu.pojo;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
public class Teacher {
    private String name = "jack";
    private int teachernum = 5;
    @Autowired
    private Student student;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getTeachernum() {
        return teachernum;
    }

    public void setTeachernum(int teachernum) {
        this.teachernum = teachernum;
    }

    public Student getStudent() {
        return student;
    }

    public void setStudent(Student student) {
        this.student = student;
    }

    @Override
    public String toString() {
        return "Teacher{" +
                "name='" + name + '\'' +
                ", teachernum=" + teachernum +
                ", student=" + student +
                '}';
    }
}
